/* static/css/index.css */

/* General styling */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background-color: #f5f5f5; /* 备用背景颜色 */
    background-image: url('../image/backgrand.png');
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: fixed;
    position: relative;
    z-index: 0;
}

body::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../image/backgrand.png');
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: fixed;
    opacity: 0.5; /* 调整透明度 */
    z-index: -1; /* 确保背景在内容后面 */
}

.container {
    flex: 1;
    z-index: 1;
    position: relative;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 10px;
    margin: 20px;
    padding: 20px;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #333;
    color: #fff;
    padding: 10px 20px;
    border-radius: 10px;
}

header h1 {
    margin: 0;
}

header nav a {
    color: #fff;
    text-decoration: none;
    font-weight: bold;
}

header nav a:hover {
    text-decoration: underline;
}

.content {
    display: flex;
    margin-top: 20px;
}

.categories {
    width: 25%;
    background: rgba(51, 51, 51, 0.8);
    color: #fff;
    padding: 20px;
    border-radius: 10px;
}

.categories h2 {
    margin-top: 0;
}

.categories ul {
    list-style-type: none;
    padding: 0;
}

.categories ul li {
    margin-bottom: 10px;
}

.categories ul li a {
    color: #fff;
    text-decoration: none;
}

.categories ul li a:hover {
    text-decoration: underline;
}

.product-list {
    width: 75%;
    padding: 20px;
}

.product-list h2 {
    margin-top: 0;
}

.product-list ul {
    list-style-type: none;
    padding: 0;
}

.product-list ul li {
    background: rgba(255, 255, 255, 0.8);
    margin-bottom: 20px;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

.product-list ul li h3 {
    margin-top: 0;
}

.recommended {
    margin-top: 20px;
}

.recommended h2 {
    margin-top: 0;
}

.recommended ul {
    list-style-type: none;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
}

.recommended ul li {
    background: rgba(255, 255, 255, 0.8);
    margin: 10px;
    padding: 20px;
    border-radius: 10px;
    flex: 1 1 calc(33.333% - 20px);
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

.recommended ul li h3 {
    margin-top: 0;
}

footer {
    background-color: #333;
    color: #fff;
    text-align: center;
    padding: 10px 0;
    margin-top: auto;
    width: 100%;
}

footer p {
    margin: 0;
}

footer ul {
    list-style-type: none;
    padding: 0;
    margin: 10px 0 0 0;
    display: flex;
    justify-content: center;
}

footer ul li {
    margin: 0 15px;
}

footer ul li a {
    color: #fff;
    text-decoration: none;
}

footer ul li a:hover {
    text-decoration: underline;
}